package yf.mall.service.app;

import com.github.pagehelper.Page;
import com.github.pagehelper.PageInfo;
import com.yf.service.BaseService;
import yf.mall.entity.AppMaterialEntity;
import yf.mall.entity.AppMaterialEntityExample;
import yf.mall.vo.AppMaterialVo;

import javax.servlet.http.HttpServletResponse;
import java.io.InputStream;
import java.util.List;
import java.util.Map;

/**
 * 素材信息表Service接口
 *
 * 
 *
 * @date Tue Jul 18 14:30:26 CST 2023
 */
public interface AppMaterialService extends BaseService<AppMaterialEntity> {

    /************自动生成**************/
    List<AppMaterialVo> findVo(AppMaterialVo vo);

        AppMaterialVo getVo(Long id);

     int updateVo(AppMaterialVo vo);

       int saveVo(AppMaterialVo vo);

    void downLoad(HttpServletResponse response, List<AppMaterialVo> list);

    void upload(InputStream file);

    List<AppMaterialEntity> listByIds(List<Long> materialIds);

    /***********BACK***********/




    /***********API***********/
    /**
     * 分页查询
     * @param example
     * @param page
     * @return
     */
    PageInfo<AppMaterialEntity> page(AppMaterialEntityExample example, Page<Object> page);

    /**
     * 通过素材id批量查询素材
     * @param materialIds 素材id
     * @param fileType 文件类型
     * @return
     */
    List<AppMaterialEntity> listByMaterialIds(List<Long> materialIds, Integer fileType);

    List<AppMaterialEntity> findAll();
}
